home *** CD-ROM | disk | FTP | other *** search
- // Name: dirdiver.h
-
- // AmigaOS
- #include <exec/types.h>
- #include <exec/memory.h>
- #include <exec/lists.h>
- #include <exec/nodes.h>
- #include <dos/exall.h>
- #include <dos/datetime.h>
- #include <libraries/dos.h>
- #include <proto/exec.h>
- #include <proto/dos.h>
- #include <proto/xpkmaster.h>
- // SAS/C
- #include <ctype.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
- #include <dos.h>
- #include <time.h>
-
- #ifndef FBACKNG_H
- #include "fbackng.h"
- #endif
-
- // phases
- #define BACKUP_PHASE 1
- #define MIRROR_PHASE 5
-
- // return codes
- #define DD_DELETED -1 // no error, but indicate file was deleted
- #define DD_OK 0 // no error
- #define DD_LOCK 1 // error locking root
- #define DD_CALLOC 2 // error allocating memory
- #define DD_ALLOCDOS 3 // error allocating dosobject
- #define DD_OPENSOURCE 4 // error opening source for copy
- #define DD_OPENDEST 5 // error opening dest for copy
- #define DD_COPY 6 // error copying source to dest
- #define DD_OPENLOG 7 // error opening logfile
- #define DD_WRITELOG 8 // error writing to logfile
- #define DD_LOCKFILE 9 // error obtaining lock on file
- #define DD_EXFILE 10 // error obtaining info on file
- #define DD_DATEFILE 11 // error setting date on file
- #define DD_DELFILE 12 // error deleting a file
- #define DD_ARCHFILE 13 // error setting archive flag on file
- #define DD_COMMFILE 14 // error setting comment on file
- #define DD_PROTFILE 15 // error setting protect on file
- #define DD_SYSTFILE 16 // error setting system date on file
- #define DD_VOLERROR 17 // volume not found
- #define DD_DELFLAG 18 // error setting delete flag
- #define DD_DELDIRS 19 // deleted a directory
-
- // externals
- extern struct Library *XpkBase;
-
- // prototypes
- int __aligned __saveds DirDiver(char *root,int mode);
- int __aligned __saveds DirCleaner(char *root);
- void check_write_log(char *custom);
- int Check_File(char *name);
- int Check_Dir(char *name);
- int Copy_File(char *infile,char *outfile);
- int Clone_Dir(char *path);
- int Set_Archive_File(char *name);
- int Clone_Protect_File(char *name,char *uit);
- int Clone_DateStamp_File(char *name,char *uit);
- int System_DateStamp_File(char *name);
- int Clone_Comment_File(char *name,char *uit);
- int Delete_File(char *thefile);
- int Delete_Dir(char *thedir);
- int Pack_File(char *in,char *out,char *packer);
- int Compare_Date_File(char *filename,struct DateTime *datum,LONG *res);
- void WhichFlags(ULONG flg,char *res);
-
- // end
-